<?php

namespace App\Models\Pay;
use Illuminate\Database\Eloquent\Model;
class Pay extends Model
{
    // 表名
    protected $table = 'pay';

    protected $dateFormat = 'U';

    const CREATED_AT = 'createtime';

    const UPDATED_AT = null;

    protected $guarded = [];

    // protected $casts = [
    //     'createtime' => 'datetime:Y-m-d H:i:s',
    // ];
    protected $appends = [
        'name_text', 
    ];
    public function getNameTextAttribute()
    {
        return $this->attributes['name'].'：￥'.$this->attributes['price'];
    }

}
